<!DOCTYPE html>
<html xmlns:th="http://www.thymeleaf.org">
<head>
    <meta charset="utf-8">
    <title>宿舍楼管理员首页</title>
    <link rel="stylesheet" type="text/css" th:href="@{css/bootstrap.min.css}"/>
    <link rel="stylesheet" type="text/css" th:href="@{css/general.css}"/>
    <script th:src="@{js/jquery-3.6.0.js}"></script>
    <script th:src="@{js/bootstrap.min.js}"></script>
    <script th:src="@{js/custom.js}"></script>
    <script th:src="@{js/ordinary/ordinary-allMenu.js}"></script>
    <script th:src="@{js/ordinary/ordinary-allTable.js}"></script>
    <script th:src="@{js/ordinary/ordinary-allSearch.js}"></script>
    <script th:src="@{js/ordinary/ordinary-allInsert.js}"></script>
    <script th:src="@{js/ordinary/ordinary-allUpdate.js}"></script>
    <script th:src="@{js/ordinary/ordinary-allDelete.js}"></script>
    <script th:inline="javascript">
        $(function () {
            let dormBuildingName = [[${session.manager.dormBuilding.dbname}]];

            as_load_d_menu(dormBuildingName);

            as_load_table(null, dormBuildingName);
            ad_load_table(null, dormBuildingName);
            av_load_table(null, dormBuildingName);
            ari_load_table(null, dormBuildingName);
        });

    </script>

</head>
<body>
<div class="container">
    <div class=" jumbotron">
        <font size="63px">您好，<span style="font-size: 30px;"><span id="ordinary-dbname">[[${session.manager.dormBuilding.dbname}]]</span>管理员:[[${session.manager.name}]]！</span></font>
        <span style="float: right;"><a class="btn btn-primary btn-lg" href="javascript:location.href='/exit';"
                                       role="button">退出登录</a></span>
    </div>
</div>
<div class="container">
    <!-- Nav tabs -->
    <ul class="nav nav-tabs nav-justified" role="tablist">
        <li role="presentation" class="active">
            <a href="#AllStudents" aria-controls="home" role="tab" data-toggle="tab">
                All Students <span class="badge" id="as-count">42</span>
            </a>
        </li>
        <li role="presentation">
            <a href="#AllDorms" aria-controls="profile" role="tab" data-toggle="tab" id="ad-a">
                All Dorms <span class="badge" id="ad-count">42</span>
            </a>
        </li>
        <li role="presentation">
            <a href="#AllVisitors" aria-controls="messages" role="tab" data-toggle="tab">
                All Visitors <span class="badge" id="av-count">42</span>
            </a>
        </li>
        <li role="presentation">
            <a href="#AllRepairInformation" aria-controls="settings" role="tab" data-toggle="tab">
                All Repair Information <span class="badge" id="ari-count">42</span>
            </a>
        </li>
    </ul>

    <!-- Tab panes -->
    <div class="tab-content">
        <div th:replace="/ordinary/ordinary-as-content :: #AllStudents"></div>

        <div th:replace="/ordinary/ordinary-ad-content :: #AllDorms"></div>

        <div th:replace="/ordinary/ordinary-av-content :: #AllVisitors"></div>

        <div th:replace="/ordinary/ordinary-ari-content :: #AllRepairInformation"></div>
    </div>
</div>
</body>
</html>
